<%@taglib  uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@taglib  uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<%@taglib uri="http://java.sun.com/jstl/core_rt" prefix="c" %>
<%@taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@taglib uri="http://jsptags.com/tags/navigation/pager" prefix="pg" %>

<TABLE class="mainService">
    <TR>
        <TD colSpan=1>
            <TABLE class="table0" cellSpacing=0 cellPadding=0 align=center>
                <TR>
                    <TD class="td1"></TD>
                    <TD class="top"></TD>
                    <TD class="topright"></TD>
                </TR>
                <TR>
                    <TD class="middleleft" rowSpan=3></TD>
                    <TD bgcolor="#hhhhhh">

                    </TD>
                    <TD class="middleright" rowSpan=3></TD>
                </TR>
                <TR>
                    <TD class="middlecenter"></TD>
                </TR>
                <TR>
                    <TD  class="main">
                        <div>
                            <table width="580" border="0"  >
                                <tr>
                                    <td rowspan="6" width="120" height="120" valign="middle" align="justify">
                                <h9>   <img src="${tourDTO.tourDetailDTO.imagesUrl}" width="150" height="150" align="top"/></h9>
                                </td>
                                <td rowspan="5">

                                </td>
                                <td height="20"><h8>TourName</h8></td>
                                <td>
                                    ${tourDTO.departure}
                                    <logic:present name="listLocation">
                                        <logic:iterate id="listL" name="listLocation">
                                            -<a href="tour.do?action=localtion&id=<bean:write name="listL" property="locationId"/>">
                                                <bean:write name="listL" property="locationName"/>
                                            </a>
                                        </logic:iterate>
                                    </logic:present>
                                    - ${tourDTO.destination}
                                </td>
                                </tr>
                                <tr>
                                    <td height="20"><h8>Depart From:</h8></td>
                                <td>
                                    ${tourDTO.departure}
                                </td>
                                </tr>
                                <tr>
                                    <td height="20"><h8>Depart From:</h8></td>
                                <td>
                                    ${tourDTO.destination}
                                </td>
                                </tr>
                                <tr>
                                    <td height="20"><h8>Duration:</h8></td>
                                <td>
                                    ${tourDTO.duration} day ${tourDTO.duration-1}night
                                </td>
                                </tr>
                                <tr>
                                    <td height="20"><h8>Price:</h8> </td>
                                <td>
                                    <font color="red" size="4">  ${min}  USD  --   ${max}  USD</font>
                                </td>
                                </tr>
                                <tr>
                                    <td colspan="4">
                                        ${tourDTO.introduction}

                                    </td>
                                </tr>

                                <tr bgcolor="#F0F0F0" >
                                    <td > <h8>Package:</h8>  </td>
                                <td>1 px</td>
                                <td>2-3 px</td>
                                <td>3-4 px</td>
                                <td>4-7 over  px</td>
                                </tr>
                                <tr onmousemove="style.backgroundColor='#E9EFF8'" onmouseout="style.backgroundColor='#ffffff'">
                                    <td > ${tourDTO.tourTypeDTO.tourTypeName} </td>
                                    <logic:present name="avgListPrice">
                                        <logic:iterate id="avg" name="avgListPrice">
                                            <td title=" ${tourDTO.departure} <logic:present name="listLocation"><logic:iterate id="listL" name="listLocation">- <bean:write name="listL" property="locationName"/></logic:iterate> </logic:present>-${tourDTO.destination}">
                                                <a href="tour.do?action=booking&id=${tourDTO.tourId}&idp=${avg.tourPriceId}">
                                                <bean:write name="avg" property="price"/></a>
                                            </td>
                                        </logic:iterate>
                                    </logic:present>
                                </tr>
                                
                                <tr >

                                    <td height="21" colspan="4" valign="top"><p><font color="red">? Click to price to book package </font></p><img src="img/line.png" width="410" height="1" align="top"  ></td>
                                </tr>

                                <tr>
                                    <td></td>
                                </tr>
                                <tr>
                                    <td colspan="6">
                                        <logic:present name="listService">
                                            <logic:iterate id="listS" name="listService">
                                                <p>           <bean:write name="listS" property="tourServiceName"/><font color="blue"><br>Price:</font><bean:write name="listS" property="tourDetailDTO.price"/><br>
                                                    <bean:write name="listS" property="tourDetailDTO.detail"/><br><img src="img/line.png" width="410" height="1" align="top"  >
                                                    <br></p>
                                                </logic:iterate>

                                        </logic:present>

                                    </td>
                                </tr>
                                <tr >
                                    <td height="21" colspan="4" valign="top"><img src="img/line.png" width="410" height="1" align="top"  ></td>
                                </tr>
                                <tr>
                                    <td colspan="6">
                                        <logic:present name="listLocation">
                                            <logic:iterate id="listL" name="listLocation">
                                                <font color="blue" size="4">
                                                    <p>
                                                        <a href="tour.do?action=localtion&id=<bean:write name="listL" property="locationId"/>">
                                                            <bean:write name="listL" property="locationName"/>
                                                        </a>

                                                    </p>
                                                </font>
                                                <p>
                                                    <bean:write name="listL" property="description"/>
                                                </p>
                                            </logic:iterate>
                                        </logic:present>
                                    </td>
                                </tr>
                                <tr>
                                    <td>
                                </tr>

                            </table>
                        </div>
                    </TD>
                </TR>
                <TR>
                    <TD class="bottom"><IMG border=0 alt="" src="img/pod_main_bottom_left.gif"></TD>
                    <TD class="bottomright"><P align=right>&nbsp;</P></TD>
                    <TD class="bottomleft"><IMG border=0 alt="" src="img/pod_main_bottom_right.gif"></TD>
                </TR>
            </TABLE>
        </TD>
    </TR>
</TABLE>
<TABLE class="mainService">
    <TR>
        <TD colSpan=2>
            <TABLE class="table0" cellSpacing=0 cellPadding=0 align=center >
                <TR>
                    <TD class="td1"></TD>
                    <TD class="top"></TD>
                    <TD class="topright"></TD>
                </TR>
                <TR>
                    <TD class="middleleft" rowSpan=3></TD>
                    <TD bgcolor="#hhhhhh">

                    </TD>
                    <TD class="middleright" rowSpan=3></TD>
                </TR>
                <TR>
                    <TD class="middlecenter"></TD>
                </TR>
                <TR>
                    <TD  class="main">
                        <pg:pager url="tour.do" maxIndexPages="3" maxPageItems="4">
                            <pg:param name="action" value="detail"  />
                            <pg:param name="id" value="${id}"/>
                            <table>
                                <tr>
                                    <td>
                                        <logic:present name="listMaxMinPrice">
                                            <logic:iterate id="listOrther" name="listMaxMinPrice">
                                                <pg:item >
                                                    <div style="float:left;padding-right:20px;padding-left:40px;padding-bottom:20px;">
                                                        <a href="tour.do?action=detail&id=<bean:write name="listOrther" property="tourDetailDTO.tourId"/>">
                                                            <bean:write name="listOrther" property="tourName"/><br>
                                                            <img src="<bean:write name="listOrther" property="tourDetailDTO.imagesUrl"/>" width="150" height="150" align="bottom"><br>
                                                            <bean:write name="listOrther" property="departure"/>-<bean:write name="listOrther" property="destination"/>

                                                            <br> <font color="red"> <bean:write name="listOrther" property="minP"/>- <bean:write name="listOrther" property="maxP"/>$</font>
                                                        </a>
                                                    </div>
                                                </pg:item>
                                            </logic:iterate>
                                        </logic:present>
                                    </td>
                                </tr>
                            </table>
                            <table>
                                <tr>
                                    <td>
                                        <pg:index>
                                            <pg:prev ><a class="pre pointer disable" href="${pageUrl}" >[&lt;&lt;Prev]</a></pg:prev>
                                            <span class="pages">
                                                <pg:pages><a class="pointer searchByPage unlink" href="${pageUrl}">${pageNumber}</a> | </pg:pages>
                                            </span>
                                            <pg:next><a  class="nxt pointer" href="${pageUrl}">[Next&gt;&gt;]</a></pg:next>
                                        </pg:index>
                                    </td>
                                </tr>
                            </table>
                        </pg:pager>
                    </TD>
                </TR>
                <TR>
                    <TD class="bottom"><IMG border=0 alt="" src="img/pod_main_bottom_left.gif"></TD>
                    <TD class="bottomright"><P align=right>&nbsp;</P></TD>
                    <TD class="bottomleft"><IMG border=0 alt="" src="img/pod_main_bottom_right.gif"></TD>
                </TR>
            </TABLE>
        </TD>
    </TR>
</TABLE>
